# Contributor: Kostin Dmitrij [DsTr] <kostindima@gmail.com>

pkgname=uimge-svn
pkgver=64
pkgrel=3
pkgdesc="Python picture uploader to different imagehostings"
arch=(any)
url="http://code.google.com/p/uimge/"
license=('GPL')
depends=(pil python)
provides=(uimge)
conflicts=(uimge)
replaces=(uimge)
source=( )
md5sums=( )

_svntrunk=http://uimge.googlecode.com/svn/trunk/src/uimgepy/
_svnmod=uimge-svn

build() {
  cd $startdir/src

  if [ -d $_svnmod/.svn ]; then
    (cd $_svnmod && svn up -r $pkgver)
  else
    svn co $_svntrunk --config-dir ./ -r $pkgver $_svnmod
  fi

  msg "SVN checkout done or server timeout"

  cd $_svnmod

  mkdir -p $startdir/pkg/usr/lib/python2.5/site-packages/libuimge
  mkdir -p $startdir/pkg/usr/bin

  install -Dm555 libuimge/* $startdir/pkg/usr/lib/python2.5/site-packages/libuimge
  install -Dm755 uimge.py $startdir/pkg/usr/bin/uimge
}
